#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
long long Fun1(long long n) {
	if (n == 1) {
		return 1;
	}
	else return 2*Fun1(n - 1) + 1;
}
long long Fun2(long long n) {
	if (n == 1) {
		return 1;
	}
	else return 2*Fun2(n - 1) + n;
}
int  main() {
	long long n = 0;
	scanf("%d", &n);
	long long x = Fun1(n);
	long long  y = Fun2(n);
	printf("%lld %lld", x, y);
	return 0;
}